import {defineStore} from "pinia";
import type {RouteRecordRaw} from "vue-router";

// import { ThemeEnum } from "@/enums/ThemeEnums";

interface GloablState {
    collapsed: Boolean;
    message: string;
    menuOptions: Array<any>;
    routes: Array<RouteRecordRaw>;
}


export const useGlobalStore = defineStore("global-store", {
    state: (): GloablState => ({
        collapsed: false,
        message: "",
        menuOptions: [],
        routes: [],
    }),
    getters: {},
    actions: {
        toggleCollapsed(): void {
            this.collapsed = !this.collapsed
        },
        changeMessage(data): void {
            this.message = data
        }
    },
});
